package cn.iocoder.yudao.module.member.dal.mysql.userfacelogs;

import java.util.*;

import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.member.dal.dataobject.userfacelogs.UserFaceLogsDO;
import org.apache.ibatis.annotations.Mapper;
import cn.iocoder.yudao.module.member.controller.admin.userfacelogs.vo.*;

/**
 * 用户面试日志 Mapper
 *
 * @author 芋道源码
 */
@Mapper
public interface UserFaceLogsMapper extends BaseMapperX<UserFaceLogsDO> {

    default PageResult<UserFaceLogsDO> selectPage(UserFaceLogsPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<UserFaceLogsDO>()
                .betweenIfPresent(UserFaceLogsDO::getCreateTime, reqVO.getCreateTime())
                .eqIfPresent(UserFaceLogsDO::getCompanyId, reqVO.getCompanyId())
                .eqIfPresent(UserFaceLogsDO::getJobId, reqVO.getJobId())
                .eqIfPresent(UserFaceLogsDO::getPoints, reqVO.getPoints())
                .eqIfPresent(UserFaceLogsDO::getUserId, reqVO.getUserId())
                .orderByDesc(UserFaceLogsDO::getId));
    }

}